package com.kaisa.activity.ui;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.webkit.WebView;
import android.widget.ImageView;

import com.kaisa.activity.R;
import com.kaisa.activity.constant.UrlHttp;

import butterknife.Bind;
import butterknife.ButterKnife;

public class CasaGoHome extends AppCompatActivity implements View.OnClickListener{

    @Bind(R.id.gohome_wb)
    WebView gohomeWb;
    @Bind(R.id.top_back)
    ImageView topBack;
    @Bind(R.id.top_share)
    ImageView topShare;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_casa_go_home);
        ButterKnife.bind(this);
        gohomeWb.getSettings().setJavaScriptEnabled(true);
        gohomeWb.loadUrl(UrlHttp.CASA_GOHOME_URL);
        initView();
        initData();
    }

    private void initData() {
        topBack.setOnClickListener(this);
        topShare.setOnClickListener(this);
    }

    private void initView() {

    }

    @Override
    public void onClick(View v) {
        switch (v.getId()){
            case R.id.top_back:
                this.finish();
                break;
            case R.id.top_share://分享
                break;
        }
    }
}
